package com.spsoft.core.model.leqidmz.param;

import com.spsoft.core.annotation.EnumValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;

/**
 * @description: 下载/退回授信额度请求参数
 * @author: dcy
 * @create: 2023-12-7
 **/
@ApiModel(value = "下载/退回授信额度")
@EqualsAndHashCode(callSuper = true)
@Data
public class ApplyCreditParams extends BaseNsrRequestParams implements Serializable {

    private static final long serialVersionUID = 1905122041950251207L;

    /**
     * 平台编号
     */
    @ApiModelProperty(value = "平台编号", required = true)
    @NotBlank(message = "平台编号不能为空")
    private String ptbh;

    /**
     * 申请类型 0 下载，1 退回
     */
    @ApiModelProperty(value = "申请类型", required = true)
    @NotBlank(message = "申请类型不能为空")
    @EnumValue(strValues = {"0", "1"}, message = "申请类型只能是：0 下载，1 退回")
    private String sqlx;

    /**
     * 业务流水号
     * 使用单位id+直连单位id+32位随机生成数
     */
    @ApiModelProperty(value = "业务流水号", required = true)
    @NotBlank(message = "业务流水号不能为空")
    private String ywlsh;

    /**
     * 申请额度
     */
    @ApiModelProperty(value = "申请额度", required = true)
    @NotNull(message = "申请额度不能为空")
    private BigDecimal sqed;

}
